package com.hiyee.pojo.bo;

import com.fasterxml.jackson.annotation.JsonProperty;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 添加购物车参数
 *
 * @author WangBin
 */
public class CartAddBO {

    @NotNull(message = "货品ID为空")
    @JsonProperty("goods_id")
    private Long goodsId;

    @NotNull(message = "商品ID为空")
    @JsonProperty("product_id")
    private Long productId;

    @NotNull(message = "商品数量为空")
    @Min(value = 1)
    private Integer qty;

    public Long getGoodsId() {
        return goodsId;
    }

    public void setGoodsId(Long goodsId) {
        this.goodsId = goodsId;
    }

    public Long getProductId() {
        return productId;
    }

    public void setProductId(Long productId) {
        this.productId = productId;
    }

    public Integer getQty() {
        return qty;
    }

    public void setQty(Integer qty) {
        this.qty = qty;
    }
}
